package mbms.mobilebudget.entity;

import java.io.Serializable;

import mbms.mobilebudget.entity.EnumValues.BankNameEnum;
import mbms.mobilebudget.entity.EnumValues.CurrencyType;

import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.table.DatabaseTable;

@DatabaseTable(tableName="credit_card")
public class CreditCard implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = -8489758272501087325L;
	
	@DatabaseField(generatedId = true)
	private Integer id;
	
	@DatabaseField(canBeNull = true)
	private String branch;
	

	@DatabaseField(canBeNull = false)
	private BankNameEnum bankName;
	
	@DatabaseField(canBeNull = false)
	private Integer lastFourDigit;
	
	@DatabaseField(canBeNull = false,foreign=true)
	private User user;
	
	@DatabaseField(canBeNull = false)
	private CurrencyType currencyType;
	
	
	@DatabaseField(canBeNull = true)
	private Double totalExpenseAmount;
	
	@DatabaseField(canBeNull = true)
	private Double totalIncomeAmount;
	
	
	public CreditCard(Integer id, String branch, BankNameEnum bankName,
			Integer lastFourDigit, User user, CurrencyType currencyType,
			Double totalExpenseAmount, Double totalIncomeAmount) {
		super();
		this.id = id;
		this.branch = branch;
		this.bankName = bankName;
		this.lastFourDigit = lastFourDigit;
		this.user = user;
		this.currencyType = currencyType;
		this.totalExpenseAmount = totalExpenseAmount;
		this.totalIncomeAmount = totalIncomeAmount;
	}

	public CreditCard() {
	}
	
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}

	public BankNameEnum getBankName() {
		return bankName;
	}

	public void setBankName(BankNameEnum bankName) {
		this.bankName = bankName;
	}

	public Integer getLastFourDigit() {
		return lastFourDigit;
	}
	public void setLastFourDigit(Integer lastFourDigit) {
		this.lastFourDigit = lastFourDigit;
	}
	public User getUser() {
		return user;
	}
	public void setUser(User user) {
		this.user = user;
	}
	public CurrencyType getCurrencyType() {
		return currencyType;
	}
	public void setCurrencyType(CurrencyType currencyType) {
		this.currencyType = currencyType;
	}
	public String getBranch() {
		return branch;
	}
	public void setBranch(String branch) {
		this.branch = branch;
	}

	public Double getTotalExpenseAmount() {
		return totalExpenseAmount;
	}

	public void setTotalExpenseAmount(Double totalExpenseAmount) {
		this.totalExpenseAmount = totalExpenseAmount;
	}

	public Double getTotalIncomeAmount() {
		return totalIncomeAmount;
	}

	public void setTotalIncomeAmount(Double totalIncomeAmount) {
		this.totalIncomeAmount = totalIncomeAmount;
	}

	
}
